package org.comet.auxiliary.client.liaobei.util;

import java.applet.Applet;
import java.applet.AudioClip;
import java.io.File;

public class AuPaly implements AudioClip {
    AudioClip sound;

    public AuPaly(String s)
    {
        try
        {
            File file = new File(s);
            sound = Applet.newAudioClip(file.toURL());
            return;
        }
        catch(Exception exception)
        {
            System.out.println(exception);
        }
    }


    @Override
    public void play() {
        sound.play();

    }

    @Override
    public void loop() {
        sound.loop();
    }

    @Override
    public void stop() {
        sound.stop();
    }
}
